home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Columbia Kermit
/
kermit.zip
/
newsgroups
/
misc.19970104-19970326
/
000298_news@columbia.edu _Fri Feb 21 14:15:51 1997.msg
< prev
next >
Wrap
Internet Message Format
|
2020-01-01
|
2KB
Return-Path: <news@columbia.edu>
Received: from newsmaster.cc.columbia.edu (newsmaster.cc.columbia.edu [128.59.35.30])
by watsun.cc.columbia.edu (8.8.5/8.8.5) with ESMTP id OAA00848
for <kermit.misc@watsun.cc.columbia.edu>; Fri, 21 Feb 1997 14:15:51 -0500 (EST)
Received: (from news@localhost)
by newsmaster.cc.columbia.edu (8.8.5/8.8.5) id OAA07344
for kermit.misc@watsun; Fri, 21 Feb 1997 14:15:50 -0500 (EST)
Path: news.columbia.edu!watsun.cc.columbia.edu!fdc
From: fdc@watsun.cc.columbia.edu (Frank da Cruz)
Newsgroups: comp.protocols.kermit.misc
Subject: Re: Problems with macro parameters containing spaces.
Date: 21 Feb 1997 19:15:49 GMT
Organization: Columbia University
Lines: 38
Message-ID: <5eks95$lq2$1@apakabar.cc.columbia.edu>
References: <330DE341.6927@uksr.hp.com>
NNTP-Posting-Host: watsun.cc.columbia.edu
Xref: news.columbia.edu comp.protocols.kermit.misc:6637
In article <330DE341.6927@uksr.hp.com>, John Bigg <jbigg@uksr.hp.com> wrote:
: It appears that if I'm passing parameters to a macro and the parameters
: contain spaces \%1 only contains the first word. e.g.
:
: C-Kermit>def mymacro { return \%1 }
: C-Kermit>asg \%a {This is some text}
: C-Kermit>echo \fexec(mymacro,\%a)
: This
:
: I thought I could work around this by using {{ }} around the parameter.
:
: C-Kermit>echo \fexec(mymacro,{{\%a}})
: This is some text
:
: which is fine. But if the text contains a } then this doesn't work
: either.
:
: C-Kermit>asg \%a {This is \125 some text}
: C-Kermit>echo \fexec(mymacro,{{\%a}})
: This is
:
It is indeed a shortcoming of the parameter passing mechanism that there is
no good way to distinguish between literal curly braces and curly braces
used for grouping. However, if the braces appear at different "levels", as
they do in your example (around \%a, and "inside" \%a), then the parser
should be able to cope. I'll have to figure out why it doesn't and come up
with a fix.
: By the way, \fchecksum and \fhexify are great additions to kermit 6,
: they have simplified my implementation of TAP and UCP protocols
: immensely.
:
That was the idea :-) C-Kermit 6.0 already comes with a simple TAP script.
You used this as a model?
What is UCP?
- Frank